﻿<%@ Page Title="" Language="C#" MasterPageFile="~/AdminM.Master" AutoEventWireup="true" CodeBehind="MWeixiu.aspx.cs" Inherits="XqWebSite.WebForm10" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <style type="text/css">


        .style6
    {
        width: 174px;
            background-color: #8F9B82;
        }
        .style9
        {
            height: 9px;
        background-color: #8F9B82;
            text-decoration: underline;
        }
    .style8
    {
        text-align: center;
        font-family: 华文隶书;
        font-size: larger;
            color: #A3BAA5;
            background-color: #DDDFDB;
        }
        .style10
    {
        width: 100%;
    }
        .style11
        {
            height: 27px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <table class="style1" style="height: 564px; width: 100%;">
    <tr>
        <td class="style6" rowspan="2">
            <asp:Menu ID="Menu1" runat="server" DataSourceID="SiteMapDataSource1" 
                        StaticDisplayLevels="2" style="font-family: 楷体">
            </asp:Menu>
        </td>
        <td class="style9">
            <asp:SiteMapPath ID="SiteMapPath1" runat="server" style="font-family: 楷体">
            </asp:SiteMapPath>
        </td>
    </tr>
    <tr>
        <td class="style8">
            <asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" />
            <table class="style10">
                <tr>
                    <td class="style11">
                        维修人员信息管理</td>
                </tr>
                <tr>
                    <td style="text-align: left">
                        维修人员ID:<asp:TextBox ID="Tex_id" runat="server"></asp:TextBox>
                        <asp:Button ID="But_cx" runat="server" Text="查询" onclick="But_cx_Click" />
                        &nbsp;&nbsp;&nbsp;&nbsp;请输入维修人员ID:<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
                            <asp:Button ID="But_sc" runat="server" Text="删除" Width="43px" />
                        &nbsp;&nbsp;
                        <asp:Button ID="But_xg" runat="server" Text="修改" onclick="But_xg_Click" />
                    </td>
                </tr>
                <tr>
                    <td>
                        <asp:GridView ID="GridView1" runat="server" AllowPaging="True" 
                            AutoGenerateColumns="False" DataKeyNames="ID" Height="300px" style="margin-top: 0px" 
                            Width="924px" onselectedindexchanged="GridView1_SelectedIndexChanged">
                            <Columns>
                                <asp:BoundField DataField="ID" HeaderText="维修人员ID" InsertVisible="False" 
                                    ReadOnly="True" SortExpression="ID" />
                                <asp:BoundField DataField="username" HeaderText="维修人员姓名" 
                                    SortExpression="username" />
                                <asp:BoundField DataField="password" HeaderText="密码" 
                                    SortExpression="password" />
                                <asp:BoundField DataField="tel" HeaderText="联系电话" SortExpression="tel" />
                            </Columns>
                        </asp:GridView>
                        <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                            ConnectionString="<%$ ConnectionStrings:WuYeGuanLiConnectionString %>" 
                            DeleteCommand="DELETE FROM [WeiXiuRenYuan] WHERE [ID] = @ID" 
                            InsertCommand="INSERT INTO [WeiXiuRenYuan] ([username], [password], [tel]) VALUES (@username, @password, @tel)" 
                            SelectCommand="SELECT * FROM [WeiXiuRenYuan]" 
                            UpdateCommand="UPDATE [WeiXiuRenYuan] SET [username] = @username, [password] = @password, [tel] = @tel WHERE [ID] = @ID">
                            <DeleteParameters>
                                <asp:Parameter Name="ID" Type="Int64" />
                            </DeleteParameters>
                            <InsertParameters>
                                <asp:Parameter Name="username" Type="String" />
                                <asp:Parameter Name="password" Type="String" />
                                <asp:Parameter Name="tel" Type="String" />
                            </InsertParameters>
                            <UpdateParameters>
                                <asp:Parameter Name="username" Type="String" />
                                <asp:Parameter Name="password" Type="String" />
                                <asp:Parameter Name="tel" Type="String" />
                                <asp:Parameter Name="ID" Type="Int64" />
                            </UpdateParameters>
                        </asp:SqlDataSource>
                    </td>
                </tr>
            </table>
        </td>
    </tr>
</table>
</asp:Content>
